package org.springframework.security.web.authentication;

import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;

import org.springframework.security.core.Authentication;

/**
 * @author Dillon
 * @date 2024/7/11
 * @slogan 致敬大师 致敬未来的你
 * @desc 空 记住我逻辑处理实现类，不做记住我处理
 */
public class NullRememberMeServices implements RememberMeServices {

	/**
	 * 定义记住我自动登录接口，用于处理记住我自动登录
	 *
	 * @param request  请求对象
	 * @param response 响应
	 * @return 认证失败
	 */
	@Override
	public Authentication autoLogin(HttpServletRequest request, HttpServletResponse response) {
		return null;
	}

	/**
	 * 定义登录失败处理接口
	 *
	 * @param request  请求对象
	 * @param response 响应对象
	 */
	@Override
	public void loginFail(HttpServletRequest request, HttpServletResponse response) {
	}

	/**
	 * 定义登录成功处理对象
	 *
	 * @param request                  请求对象
	 * @param response                 响应对象
	 * @param successfulAuthentication 自动登录认证成功对象
	 */
	@Override
	public void loginSuccess(HttpServletRequest request, HttpServletResponse response,
			Authentication successfulAuthentication) {
	}

}
